-- GENERATED SPELL FOR [Lisaile Fireweaver] --


function spell0_18583(pUnit, Event) --@Fire Nova,Self--
pUnit:FullCastSpellOnTarget(12470,pUnit)
pUnit:RegisterEvent('Sorts_18583', 2000, 1)
end

function spell1_18583(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(9053,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_18583', 3000, 1)
end

function spell2_18583(pUnit, Event) --@Sun Shield,Self--
pUnit:FullCastSpellOnTarget(32932,pUnit)
pUnit:RegisterEvent('Sorts_18583', 624, 1)
end

function Sorts_18583(pUnit, Event)
local choix_sorts_18583 = math.random(0, 2)
if choix_sorts_18583 == 0 then
pUnit:RegisterEvent('spell0_18583', 1, 1)
end
if choix_sorts_18583 == 1 then
pUnit:RegisterEvent('spell1_18583', 1, 1)
end
if choix_sorts_18583 == 2 then
pUnit:RegisterEvent('spell2_18583', 1, 1)
end
end

function mob18583_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_18583', math.random(1500, 3000), 1)
end

function mob18583_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18583_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob18583_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(18583, 1, 'mob18583_Action')
RegisterUnitEvent(18583, 2, 'mob18583_Leave')
RegisterUnitEvent(18583, 3, 'mob18583_Kill')
RegisterUnitEvent(18583, 4, 'mob18583_Die')
